load(
    "//tools:defaults.bzl",
    "markdown_to_html",
    "ng_module",
    "ng_test_library",
    "ng_web_test_suite",
)

package(default_visibility = ["//visibility:public"])

ng_module(
    name = "portal",
    srcs = glob(
        ["**/*.ts"],
        exclude = ["**/*.spec.ts"],
    ),
    module_name = "@angular/cdk/portal",
    deps = [
        "//src:dev_mode_types",
        "@npm//@angular/core",
    ],
)

ng_test_library(
    name = "unit_test_sources",
    srcs = glob(
        ["**/*.spec.ts"],
        exclude = ["**/*.e2e.spec.ts"],
    ),
    deps = [
        ":portal",
        "@npm//@angular/common",
    ],
)

ng_web_test_suite(
    name = "unit_tests",
    deps = [":unit_test_sources"],
)

markdown_to_html(
    name = "overview",
    srcs = [":portal.md"],
)

filegroup(
    name = "source-files",
    srcs = glob(["**/*.ts"]),
)
